package com.bcxj.servicepay.service;

import com.bcxj.internalcommon.dto.OrderRequest;
import com.bcxj.internalcommon.entity.OrderInfo;
import com.bcxj.servicepay.client.ServiceOrderClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * ClassName: AlipayService
 * Package: com.bcxj.servicepay.service
 * Description:
 *
 * @Author BCXJ
 * @Create 2024/11/24 22:37
 * @Version 1.0
 * @Since 1.0
 */
@Service
public class AlipayService {


    @Autowired
    private ServiceOrderClient serviceOrderClient;

    /**
     * 回调service-order 订单完成的功能
     * @param orderId
     */
    public void pay(String orderId) {
        OrderRequest orderRequest = new OrderRequest();
        orderRequest.setOrderId(Long.parseLong(orderId));
        serviceOrderClient.pay(orderRequest);
    }
}
